//
//  CBUniversalTool.swift
//  CBPickerViewDemo
//
//  Created by Creater on 2018/9/26.
//  Copyright © 2018年 Creater. All rights reserved.
//

import UIKit

class CBUniversalTool {
    
    static func pickerHeight() -> CGFloat {
        if self.isIphoneX() == true {
            return 240.0
        } else {
            return 220.0
        }
    }
    
    static func bottomMargin() -> CGFloat {
        if self.isIphoneX() == true {
            return 20.0
        } else {
            return 0.0
        }
    }
    
    static func isIphoneX() -> Bool {
        if UIScreen.main.bounds.height == 812 {
            return true
        }
        return false
    }
}
